This page last changed on Feb 25, 2009 by aunger.

Intra-session object support in the teacher dashboard

The intra-session objects need to be handled slightly differently in order for them to work correctly in a teacher dashboard.

First, OTMultiUser object and the correct Multi-User teacher view needs to be passed to the scripts, so that the viewid can be set correctly:

<OTViewEntry objectClass="org.concord.otrunk.intrasession.OTMultiUser" viewClass="org.concord.otrunk.intrasession.ui.OTMultiUserConcatTeacherView" id="40d7460a-e55f-47bc-9668-6d13a4835ce1"/>
<OTScriptVariable name="graph" reference="ba4e487a-06ad-4f9f-a3c6-40630bc7fdef"/>
<OTScriptVariable name="picknview" reference="40d7460a-e55f-47bc-9668-6d13a4835ce1"/>

Second, the ruby script needs to set up a way to embed an object with a specific view:

Unable to find source-code formatter for language: ruby. Available languages are: actionscript, html, java, javascript, none, sql, xhtml, xml
def embedObject(obj, view=nil)
  if view
    "<object refid=\"#{ obj.otExternalId() }\" viewid=\"#{ view.otExternalId() }\" />"
  else
    "<object refid=\"#{ obj.otExternalId() }\" />"
  end
end

Finally, in the ERB template, add embed the object of interest, with the correct view.

<%= embedObject($graph, $picknview) %>
Document generated by Confluence on Jan 27, 2014 16:43